using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using Blazing.BusinessObjects.Locations;

namespace Blazing.UI.Cms.Admin.Usercontrols.Extension
{
    public partial class SelectAddressType : System.Web.UI.UserControl
    {
        public AddressType AddressType
        {
            get
            {
                if (!string.IsNullOrEmpty(DropDownList1.SelectedValue))
                    return AddressType.Load(int.Parse(DropDownList1.SelectedValue));
                return null;
            }
            set
            {
                if (value != null)
                {
                    DropDownList1.SelectedValue = value.ID + "";
                }
            }
        }

        protected void Page_Load(object sender, EventArgs e)
        {

        }
    }
}